<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title>隐式迭代</title>
    <style type="text/css">
        li {line-height:22px;}
    </style>
</head>
<body>
<ul id="menu1">
    <li>数码产品</li>
    <li>家用电器</li>
    <li>妇幼保健</li>
    <li>时尚丽人</li>
</ul>
<script src="js/jquery-1.12.4.js" type="text/javascript"></script>
<script type="text/javascript">
    $(function () {
        //$("li:even").css("background-color","red");

        //var ul=document.getElementById("menu1");
        //alert(ul.innerHTML);
        var $ul=$("#menu1");
        var d_ul=$ul.get(0);
        d_ul.style.color="yellow";
        //alert($("#menu1").html());
        //var $menu1=$=$(ul);
        //$menu1.css("font-size","30px");
    });
    /*var lis=document.getElementsByTagName("li");
    for (var i=0;i<lis.length;i++){
        if (i%2==0){
            lis[i].style.backgroundColor="red";
        }
    }*/
</script>

</body>
</html>